package com.just.springboothotdeploy;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping
public class DemoController {
    @Autowired
    private DemoService demoService;
    @GetMapping({"/","hello1"})
    public String hello1(){
        return "hello，暴走皮皮虾，啊哈哈哈哈哈";
    }

    @GetMapping("/hello2")
    public String hello2(){
        return "我是新增的";
    }
    @GetMapping("/findOne")
    public String findOne(){
       return demoService.findOne();
    }
}
